<?php

declare(strict_types=1);
/**
 * Created by PhpStorm.
 * User: yangfan
 * Date: 2019/12/11
 * Time: 4:00 PM
 */

namespace App\Utils;

use Illuminate\Support\Facades\Log;

/**
 * 用户注册领取优惠券后是否弹出提示页
 * Class RegisterReceiveCouponRemindPageUtil
 */
class RegisterReceiveCouponRemindPageUtil
{
    public const key = 'show-get-register-coupon';

    /**
     * @return void
     */
    public static function setFlag()
    {
        Log::debug('设置弹窗页面标识');
        session()->put(self::key, 1);
    }

    /**
     * @return bool
     */
    public static function isShow()
    {
        return false;
        if (session()->get(self::key)) {
            session()->forget(self::key);

            return true;
        }

        return false;
    }
}
